package com.yunshang.shoppingmall.service.impl;

import com.yunshang.shoppingmall.entity.IndexProduct;
import com.yunshang.shoppingmall.mapper.IndexProductMapper;
import com.yunshang.shoppingmall.service.IndexProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("indexProductService")
public class IndexProductServiceImpl implements IndexProductService {
    @Autowired
    IndexProductMapper indexProductMapper;

    @Override
    public int insert(IndexProduct record) {
        return indexProductMapper.insert(record);
    }

    @Override
    public int insertSelective(IndexProduct record) {
        return indexProductMapper.insertSelective(record);
    }

    @Override
    public List<IndexProduct> selectProductListByActiveSignAndProductUpState(IndexProduct indexProduct) {
        return indexProductMapper.selectProductListByActiveSignAndProductUpState(indexProduct);
    }

    @Override
    public List<IndexProduct> selectProductListByRJClassIdAndUpState(IndexProduct indexProduct) {
        return indexProductMapper.selectProductListByRJClassIdAndUpState(indexProduct);
    }
}
